using DevelopmentKit.Cms.Domain;
using FluentNHibernate.Automapping;
using FluentNHibernate.Automapping.Alterations;

namespace DevelopmentKit.Cms.Infrastructure.NHibernateMaps
{
    public class ContentPropertyMap : IAutoMappingOverride<ContentProperty>
    {
        public void Override(AutoMapping<ContentProperty> mapping)
        {
            mapping.HasMany(x => x.PropertyValids).Cascade.AllDeleteOrphan(); 
        }
    }
}